﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data;

namespace libInventory.BUS
{
    public sealed class clsInterfaceAdditionalServices :IDisposable
    {
        private clsBUSAdditionalServices _BUS;

        public clsInterfaceAdditionalServices()
        {
            _BUS = new clsBUSAdditionalServices();
        }

        public bool set_CommitUpdateSaveAdditionalServices()
        {
             return _BUS.set_CommitUpdateSaveAdditionalServices();
        }

        public DataRow[] getset_DestinationAditionalCharges
        {
            get
            {
                return _BUS.getset_DestinationAditionalCharges;
            }
            set
            {
                _BUS.getset_DestinationAditionalCharges = value;
            }
        }
        public bool set_PaidHeaders()
        {
            return _BUS.set_PaidHeaders(); 
        }
        
        public DataTable get_PaidHeaders
        {
            get
            {
                return _BUS.get_PaidHeaders;
            }
        }
                
        public DataRow[] getset_OriginAditionalCharges
        {
            get
            {
                return _BUS.getset_OriginAditionalCharges;
            }
            set
            {
                _BUS.getset_OriginAditionalCharges = value;
            }
        }

        public bool set_LoadAdditionalServicesHeader(string strPaidHeadersID)
        {
            return _BUS.set_LoadAdditionalServicesHeader(strPaidHeadersID); 
        }

        public bool set_InsertUpdateAdditionalServices(DataTable dtSource)
        {
            bool bolStatus = false;
            try
            {
                bolStatus = _BUS.set_InsertUpdateAdditionalServices(dtSource);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message + " set_InsertUpdateAdditionalServices"); 
            }

            return bolStatus;
        }

        public bool set_LoadTransactions(string strAdditionalSetHeaderID)
        {
            bool bolStatus = false;
            try
            {
                bolStatus = _BUS.set_LoadAdditionalServices(strAdditionalSetHeaderID); 
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message + " set_LoadTransactions"); 
            }

            return bolStatus;
        }

        public clsBUSAdditionalServices get_AdditionalServices
        {
            get
            {
               return _BUS;
            }
        }

        public string getset_GoodReceivedNote
        {
            get
            {
                return _BUS.getset_GoodReceivedNote; 
            }
            set
            {
                _BUS.getset_GoodReceivedNote = value;
            }
        }

        public string getset_ConsigneeID
        {
            get
            {
                return _BUS.getset_ConsigneeID;
            }
            set
            {
                _BUS.getset_ConsigneeID = value;
            }
        }

        public string getset_ShipperID
        {
            get
            {
                return _BUS.getset_ShipperID;
            }
            set
            {
                _BUS.getset_ShipperID = value;
            }
        }

        public string getset_3rdParty
        {
            get
            {
                return  _BUS.getset_3rdParty;
            }
            set
            {
                _BUS.getset_3rdParty = value;
            }

        }

        public void Dispose()
        {
            GC.Collect();
            //throw new NotImplementedException();
        }

        public libDAL.cls_DAL get_DAL
        {
            get
            {
                return _BUS.get_DAL;
            }
        }

        internal DataRow[] get_OriginAdditionalCharges()
        {
            return _BUS.get_OriginAdditionalCharges();
        }


        internal DataRow[] get_DestinationAdditionalCharges()
        {
            return _BUS.get_DestinationAdditionalCharges();
        }

        internal bool get_CheckHeaderAndDetailsLoaded()
        {
            return _BUS.get_CheckHeaderAndDetailsLoaded();
        }

        internal void set_TransferToDataset(DataTable dtStorage)
        {
            _BUS.set_TransferToDataset(dtStorage);
        }

        //public string getset_SalesTermAdditionalHeaderID
        //{
        //    get
        //    {
        //        return _BUS.getset_SalesTermAdditionalHeaderID;
        //    }
        //    set
        //    {
        //        _BUS.getset_SalesTermAdditionalHeaderID = value;
        //    }
        //}

        internal bool set_CreateNewRowAdditionalServicesHeader()
        {
            return _BUS.set_CreateNewRowAdditionalServicesHeader();
        }
        public DataRow set_NewHeaderRow
        {
            get
            {
                return _BUS.set_NewHeaderRow; 
            }
            set
            {
                _BUS.set_NewHeaderRow = value;
            }
        }
        public string getset_AdditionalServicesDescription
        {
            get
            {
                return _BUS.getset_AdditionalServicesDescription;
            }
            set
            {
                _BUS.getset_AdditionalServicesDescription = value;
            }
        }

        public string getset_AdditionalServicesHeaderID
        {
            get
            {
                return _BUS.getset_AdditionalServicesHeaderID;
            }
            set
            {
                _BUS.getset_AdditionalServicesHeaderID = value;
            }
        }

        internal bool set_CommitUpdateSaveAdditionalServicesHeader()
        {
           return _BUS.set_CommitUpdateSaveAdditionalServicesHeader();
        }

        public string getset_SalesTermHeaderID
        {
            get
            {
                return _BUS.getset_SalesTermHeaderID;
            }
            set
            {
                _BUS.getset_SalesTermHeaderID = value;
            }
        }
    }
}
